Promise.prototype.finally2=function(Onfinally){
    return this.then(Onfinally,Onfinally)
}

const p=new Promise((resolve,reject)=>{
    resolve(1)
    // reject('error2')
}) 
p.then(res=>console.log('res:',res)).finally2(res=>console.log('结束啦'))